Distinguishing closed and open respiratory airway apneas by complex admittance values

ABSTRACT

Methods and apparatus are disclosed for determining the occurrence of a closed or open apnea. Respiratory air flow from a patient is measured to give an air flow signal. The determination of an apnea is performed by applying an oscillatory pressure waveform of known frequency to a patient&#39;s airway, calculating a complex quantity representing a patient admittance ( 12 ) and comparing its value with ranges ( 14,16 ) indicative of open or closed apneas. The method distinguishes open from closed apneas even when the model used to calculate admittance is not based on details of the respiratory apparatus. In addition the patient admittance may be compared with admittance during normal breathing to avoid having to characterize the airway.

CROSS-REFERENCE TO RELATED APPLICATIONS

The present application is a divisional of U.S. patent application Ser.No. 12/376,136, filed on Feb. 3, 2009, which application is a nationalphase entry under 35 U.S.C. §371 of International Application No.PCT/AU2007/001257 filed Aug. 30, 2007, which claims priority from U.S.Provisional Patent Application No. 60/916,147 filed May 4, 2007 and U.S.Provisional Patent Application No. 60/823,973 filed Aug. 30, 2006, allof which are hereby incorporated herein by reference.

FIELD OF THE INVENTION

This invention relates to the discrimination of open and closed apneas(i.e. the complete cessation of breathing). In an open apnea the airwayis patent, while in a closed apnea there is a total obstruction of theairway. The discrimination between such apneas is advantageous in thediagnosis and treatment of respiratory conditions that have adverseeffects on a person's wellbeing.

BACKGROUND OF THE INVENTION

The expression “airway” as used herein is to be understood as theanatomical portion of the respiratory system between the nares and thebronchi, including the trachea. The expression “respiration” is to beunderstood as the continually repeating events of inspiration (inhaling)followed by expiration (exhaling).

In the Sleep Apnea syndrome a person stops breathing during sleep.Cessation of airflow for more than 10 seconds is called an “apnea”.Apneas lead to decreased blood oxygenation and thus to disruption ofsleep. Apneas are traditionally categorized as either central, wherethere is no respiratory effort, or obstructive, where there isrespiratory effort. With some central apneas, the airway is patent, andthe subject is merely not attempting to breathe. Conversely, with othercentral apneas and all obstructive apneas, the airway is not patent(i.e. occluded). The occlusion is usually at the level of the tongue orsoft palate. The airway may also be partially obstructed (i.e. narrowedor partially patent). This also leads to decreased ventilation(hypopnea), decreased blood oxygenation and disturbed sleep.

The dangers of obstructed breathing during sleep are well known inrelation to the Obstructive Sleep Apnea (OSA) syndrome. Apnea, hypopneaand heavy snoring are recognized as causes of sleep disruption and riskfactors in certain types of heart disease. Increased upper airwayresistance (Upper Airway Resistance syndrome) during sleep withoutsnoring or sleep apnea also can cause sleep fragmentation and daytimesleepiness.

The common form of treatment of these syndromes is the administering ofContinuous Positive Airway Pressure (CPAP). Briefly stated, CPAPtreatment acts as a pneumatic splint of the airway by the provision of apositive pressure, usually in the range 4-20 cm H₂O. The air is suppliedto the airway by a motor driven blower or other flow generator (FG)whose outlet passes via an air delivery hose to a nose (or nose and/ormouth) mask sealingly engaged to a patient's face. An exhaust port isprovided in the delivery tube proximate to the mask. More sophisticatedforms of CPAP, such as bi-level CPAP and autosetting CPAP, are describedin U.S. Pat. Nos. 5,148,802 and 5,245,995 respectively.

As noted, central apneas need not involve an obstruction of the airway,and often occur during very light sleep and also in patients withvarious cardiac, cerebrovascular and endocrine conditions unrelated tothe state of the upper airway. In those cases where the apnea occurswithout obstruction of the airway, there is little benefit in treatingthe condition by techniques such as CPAP. In automated CPAP systems, itis important to accurately distinguish apneas with an open airway fromapneas with a closed airway, in order to avoid inappropriatelyincreasing the CPAP splinting air pressure. Such unnecessary increasesin pressure reflexly inhibit breathing, further aggravating thebreathing disorder.

U.S. Pat. No. 5,245,995 describes how snoring and abnormal breathingpatterns can be detected by inspiration and expiration pressuremeasurements while sleeping, thereby leading to early indication ofpreobstructive episodes or other forms of breathing disorder.Particularly, patterns of respiratory parameters are monitored, and CPAPpressure is raised on the detection of pre-defined patterns to provideincreased airway pressure to, ideally, prevent the occurrence of theobstructive episodes and the other forms of breathing disorder.

Prior Use of the Forced Oscillation Technique

U.S. Pat. No. 5,704,345, entitled “Detection Of Apnea And Obstruction OfThe Airway In The Respiratory System” describes various techniques forsensing and detecting abnormal breathing patterns indicative ofobstructed breathing, including the determination of airway patency by aforced oscillation technique (FOT) in which an oscillatory pressurewaveform of known frequency is applied to a patient's airway and themagnitude of the component of an airflow signal at the known frequencyinduced by the oscillatory pressure waveform is calculated and comparedwith a threshold value. The present invention is an improvement of themethods and apparatus disclosed in the '345 patent.

The use of pressure oscillations at frequencies of the order of 4 Hz todetermine airway patency was used in the ResMed AutoSet Clinicalautomatic CPAP device and the PII Plus. In these machines which usedFOT, the pressure was measured at the mask, and the flow was measuredvery close to the mask, on the patient side of the mask vent. Thepresent invention finds an advantage in measuring pressure and flow ator near the flow generatory at least for analyzing the effect of theforced oscillation technique.

The prior art implementations of FOT are less accurate in distinguishingbetween closed and open apneas when there is present moderate leak andmoderate “resistance” in the airpath between the flow generator and thepatient. For example, a passive patient simulation consisting of a 3-4cm H₂O/(l/s) resistance, with an adjustable leak, would indicate an openairway at a leak of 15 l/min and a closed airway at a leak of 20 l/min.What is needed is a system that more accurately distinguishes betweenopen and closed apneas. In particular what is needed is a system thatgoes beyond treating the components of the airpath simply as nonlinearresistances and which utilizes an algorithm that takes into account thecapacitive and inductive components of the airpath impedance.

BRIEF SUMMARY OF THE INVENTION

In a prior filed U.S. Provisional Patent Application Ser. No.60/823,973, filed Aug. 30, 2006, it was disclosed that an effectivemethod for discriminating between closed and open respiratory airwayapneas was by determining the complex admittance of a patient airway andcomparing the absolute value of the complex admittance to thresholdvalues. That disclosure employed an algorithm that takes into accountthe patient circuit and models each component (patient circuit, ventflow and leak) in order to determine the patient pressure and flow. Inparticular, the small-signal hose pressure drop was modeled as a twoport network in which the parameters were a function of mean flow. Thepresent invention includes embodiments that are an improvement on thattechnique by including more information from that complex quantity,namely the phase angle of the admittance, or both the real and imaginarycomponents of the complex quantity, in discriminating between open andclosed apneas. In particular, it has been surprisingly discovered byanalyzing data previously identified with open and closed apneas, thatthere is significantly better separation of the data if the phase angleof the admittance is taken into account. In addition, the previoussystem is simplified by modeling the pressure drop without having tomeasure the AC impedance of the patient circuit across a range of flows.

A plot of the magnitude of admittance against the phase of admittanceprovides distinct areas of the plot that indicate open or closedairways. Alternatively, the real part of the admittance may be plottedagainst the imaginary part in an Argand diagram, resulting again indistinct areas of the diagram being associated with open and closedapneas.

The invention provides an improved method and apparatus for treating apatient subject to apneas. In particular it relies upon improved methodsfor determining whether an apnea is closed or open, by identifying setsof values of the complex patient admittance that are respectivelycharacteristic of open or closed apneas. The admittance is thereciprocal of the complex impedance of the apparatus parameterized forexample as a two port model of flow impedance or determining resistiveand inertial components from a theoretical model employing empiricallyderived resistive constants and theoretically determined flow inertanceconstants.

A sinusoidal (e.g. 4 Hz) pressure oscillation is applied at the input tothe airpath, while flow and pressure is measured both at the input andoutput of the airpath. Based upon the two port model or the moretheoretical hose drop model, the admittance is determined from the ACcomponent of the patient airflow (found by subtracting the AC componentsof vent flow and leak) and the AC component of the mask pressure. Thevent flow, in turn, is determined from an improved quadraticrelationship to mask pressure in the case of the two port model, or alinearized calculation in the more theoretical hose drop model. The leakis determined from an estimated leak coefficient. The calculation of ACcomponents of these quantities is improved over prior estimations byusing Fourier sine and cosine components at the input oscillationfrequency rather than by approximating an orthonormal set of functionsby square waves.

The invention discloses a method for determining patency of the airwayof a patient, the method comprising the steps of:

applying an oscillatory pressure waveform of known frequency to thepatient's airway;

measuring respiratory air flow and pressure at the flow generator;

calculating the AC values of flow and pressure at the mask from a 2-portimpedance model,

determining that the airway is patent by determining whether the complexadmittance is in a region characteristic of patency.

Advantageously the admittance is determined from the ratio of AC valuesof patient flow and mask pressure, and there is the step of comparingthe value of the complex admittance with ranges of values for which theairway is declared patent.

The invention yet further discloses a method for determining the degreeof patency of the airway of a patient, the method comprising the stepsof:

applying an oscillatory pressure waveform of known frequency, magnitudeand phase at an entrance to the patient's airway;

measuring respiratory air flow from the patient;

determining the magnitude and phase of the component of said air flow atsaid known frequency induced by said oscillatory pressure waveform; and

determining the degree of patency as the location of the complexadmittance within the region indicative of patency.

To minimize the effect of the delivery system not supplying apredetermined waveform in the aforementioned method, the pressurewaveform actually produced is measured. In this technique we initiallyapply a waveform of some amplitude at the flow generator, calculate orobserve the magnitude of the pressure waveform at the mask, then adjust(typically increasing) the amplitude at the flow generator in order toproduce a desired amplitude at the mask. Given that the system isapproximately linear for these small signals, the calculation as to howmuch to increase the driving waveform is a calculation of the radio ofthe desired to the actual pressure magnitude at the mask. The advantageof this approach is an improvement in the signal to noise ratio.

The invention yet further discloses a method for controlling theadministration of CPAP treatment to the airway of a patient by meanscontrollable to supply breathable air to the patient's airwaycontinually at a selectable pressure elevated above atmosphericpressure, the method comprising the step of:

commencing or increasing CPAP treatment pressure if an apnea isoccurring, determined by the steps of:

measuring respiratory air flow from the patient as a function of time;and

determining the deviation of said admittance from the centroid of theregion of patency.

The invention yet further discloses apparatus for determining patency ofthe airway of a patient, the apparatus comprising:

means for applying an oscillatory pressure waveform of known frequencyto the patient's airway;

means for measuring respiratory air flow from the patient; and

means for determining that the airway is patent if there is anadmittance within a patency region at said known frequency induced bysaid oscillatory pressure waveform.

The invention yet further discloses apparatus for determining the degreeof patency of the airway of a patient, the apparatus comprising:

means for applying an oscillatory pressure waveform of known frequencyand magnitude to the patient's airway;

means for determining the complex admittance of respiratory air flowfrom the patient; and

means for determining the degree of patency as the deviation of saidinduced admittance from the centroid of a patency region.

The invention yet further discloses a method of distinguishing betweenopen and closed airway apneas of a patient comprising the steps of:

(i) connecting a respiratory device to a patient via an air deliverytube and a patient interface;

(ii) delivering an alternating pressure waveform to the patient from therespiratory device to the patient via the air delivery tube;

(iii) measuring a flow rate and pressure of air at the respiratorydevice;

(iv) determining a capacitive component of an air delivery tubeimpedance;

(v) determining a patient admittance from said measured flow andpressure of air and said capacitive component;

(vi) distinguishing between an open and closed airway apnea on the basisof said patient admittance.

The invention yet further discloses method of distinguishing betweenopen and closed airway apneas of a patient comprising the steps of:

(i) connecting a respiratory device to a patient via an air deliverytube and a patient interface;

(ii) delivering an alternating pressure waveform to the patient from therespiratory device to the patient via the air delivery tube;

(iii) measuring a flow rate and pressure of air at the respiratorydevice;

(iv) determining an inductive component of an air delivery tubeimpedance;

(v) determining a patient admittance from said measured flow andpressure of air and said capacitive component;

(vi) distinguishing between an open and closed airway apnea on the basisof said patient admittance.

In another form of the invention patency of the airway is determined tobe unknown, or in a “don't know” region. Another aspect of the inventionis that patency is defined as having a gradual scale from open toclosed. Another aspect is that apnea discrimination regions are definedin the complex plane, the regions not necessarily being contiguous. Afurther refinement is that the discrimination regions may be functionsof the average leak level; in particular, the don't-know regionsprobably increase in size with increasing leak.

Further forms of the invention are as set out in the claims.

BRIEF DESCRIPTION OF THE DRAWINGS

Embodiments of the invention will now be described with reference to theaccompanying drawings, in which:

FIG. 1 shows a flow diagram of the basic methodology of an embodiment;

FIG. 2 shows, in diagrammatic form, apparatus embodying the invention;

FIG. 3 shows an electronic analogue of the 2-port analysis of thepresent invention.

FIG. 4 shows values of the complex admittance based on a detailedalgorithm.

FIG. 5 shows values of the complex admittance based on a simplifiedalgorithm.

DETAILED DESCRIPTION

A System Implementing the Invention

The present invention is an improvement upon the embodiments disclosedin U.S. Pat. No. 5,704,345, which is incorporated by reference in itsentirety. FIG. 1 is a flow diagram of the basic methodology of oneembodiment of the present invention. The first step 10 of the presentinvention is the measurement of respiratory flow and pressure at pointsnear the flow generator over time where an apnea is occurring. Thisinformation is processed in step 12 to generate admittance values to beused as qualitative measures for subsequent processing. Steps 14-16detect whether a closed, open or mixed apnea is occurring by comparisonof the complex admittance value in a time window with a patency region.

If an apnea is in progress there then follows a determination whetherthe apnea is open or closed. If an apnea with an open airway isoccurring, and, if desired, the event is logged in step 18. If theresult of step 16 is that an apnea with a closed airway is occurring, anincrease in CPAP treatment pressure occurs in step 20. If desired, step20 may include the optional logging of the detected abnormality.

In the instance of an apnea with an open airway the CPAP treatmentpressure is reduced, in accordance with usual methodologies that seek toset the minimal pressure required to obviate, or at least reduce, theoccurrence of apneas. The amount of reduction in step 22 may, ifdesired, be zero.

The methodology represented in FIG. 1 is of a clinical embodiment, wherepatient CPAP pressure is controlled over time as appropriate. A purelydiagnostic embodiment operates in the same manner except it omits theCPAP pressure increase and pressure decrease actions of step 20 and step22 respectively.

FIG. 2 shows, in diagrammatic form, clinical CPAP apparatus inaccordance with one embodiment for implementing the methodology ofFIG. 1. A mask 30, whether either a nose mask and/or a face mask, issealingly fitted to a patient's face. Fresh air, or oxygen enriched air,enters the mask 30 by flexible tubing 32 which, in turn, is connectedwith a motor driven turbine (flow generator) 34 to which there isprovided an air inlet 36. The motor 38 for the turbine is controlled bya motor-servo unit 40 to either increase or decrease the pressure of airsupplied to the mask 30 as CPAP treatment. The mask 30 also includes anexhaust port 42 that is close to the junction of the tubing 34 with themask 30.

Adjacent to the flow generator 34 is a flow-resistive element 44. Thiscan take the form of an iris across which a differential pressureexists. The mask side of the flow-resistive element 44 is connected by asmall bore tube 46 to a pressure transducer 48 and to an input of adifferential pressure transducer 60. Pressure at the other side of theflow-resistive element 44 is conveyed to the other input of thedifferential pressure transducer 50 by another small bore tube 52.

The pressure transducer 48 generates an electrical signal in proportionto the flow pressure, which is amplified by amplifier 56 and passed bothto a multiplexer/ADC unit 58 and to the motor-servo unit 40. Thefunction of the signal provided to the motor-servo unit 40 is as a formof feedback to ensure that the static pressure is controlled to beclosely approximate to the set point pressure.

The differential pressure sensed across the flow-resistive element 44 isoutput as an electrical signal from the differential pressure transducer50, and amplified by another amplifier 60. The output signal from theamplifier 56 therefore represents a measure of the mask or respiratoryairflow rate. The controller 62 is programmed to perform a number ofprocessing functions.

The pressure and flow may be considered to be composed of steady statevalues and AC values, the latter reflecting the effect of a imposedoscillatory signal on the pressure having a frequency of 4 Hz. In whatfollows, a “steady-state” quantity is either (a) one from which theoscillatory component has been deliberately removed, for example by afiltering operation, or (b) is the result of a calculation based partlyor wholly on quantities from which the oscillatory component has beenremoved, or (c) is a quantity which is calculated based on instantaneousquantities, such as pressure and flow measured at the flow generator(which thus include an oscillatory component), and a model of theairpath and patient leak which either partly or wholly ignores thereactive components of the system and treats it simply as a (possiblynonlinear) system of resistances. The steady state pressure loss alongtubing 32 is calculated from the flow through the tube, and knowledge ofthe static pressure-flow characteristic of the tubing, for example bytable lookup. The steady state pressure at the mask is then calculatedby subtracting the tube pressure loss. The pressure loss along tube 32is then added to the desired set pressure at the mask to yield thedesired instantaneous pressure at the pressure generator 34. The flowthrough the exhaust 42 is calculated from the pressure at the mask fromthe pressure-flow characteristic of the exhaust, for example by tablelookup. The steady state mask flow is calculated by subtracting the flowthrough the exhaust 42 from the flow through the tubing 32. The steadystate patient flow is then calculated by subtracting the steady-stateestimated leak, which may be determined for example in a CPAP device bya 1st order low pass filter with a time constant of 10 seconds whoseinput is the instantaneous mask flow, from the steady-state mask flow.

The methodology put into place by the controller 62 will now bedescribed with reference to the apparatus of FIG. 2. If the patientrespiratory flow is very low or zero (note that the mask flow will notcease when the patient is apnoeic if there is any leak), a determinationof airway patency (steps 14-16) is made by using an externally inducedoscillation technique. If the airway is open, but the respiratorymuscles are relaxed (i.e. a central apnea with open airway), then smallexternally originating fluctuations in the mask pressure will induce asmall respiratory airflow by inflating and deflating the lungs, and bycompressing and decompressing the gas in the lungs. Conversely, if theairway is closed, no airflow will be induced. This is quantified asfollows:

Discriminating Apneas by Admittance Thresholds

The admittance Y is given byY=G+iBwhere G is conductance and B is susceptance

In order to decide whether the airway is open, the complex value of thepatient admittance, Y, is compared with a region of values. The value ofthis threshold may be selected on the basis of the followingobservations.

An explanation for the angle being a better classifier than themagnitude is possibly related to the interaction of the compleximpedances in the circuit. The leak and vent flow are essentiallynon-linear resistances with no complex (j) component. The patient isbasically a resistance and compliance (capacitance) in series to ground.The hose drop also has a complex component in the form of the inertanceof the flow. So the magnitude of the overall impedance is influenced byall components (hose, leak, vent flow, patient airway) as they all havereal parts. However the imaginary component is the interaction betweenthe inertial hose drop and the capacitive lungs. It is comparing therelative “strengths” of the inertial and capacitive reactances.

It is also possible to use the real and imaginary parts of the impedancerather than the angle and magnitude. This has an advantage of reducedCPU load. The magnitude calculation requires a square root and the anglecalculation involves an inverse tan. (Both of these can be done toeasily the required accuracy by techniques involving lookup tables,which are computationally fairly cheap.) Using both the real andimaginary or magnitude and angle gives a more robust classification. Thegrouping of the open and closed values becomes much more apparent.

As determined from the values in FIG. 4, a possible set of thresholdswould be

angle = ARG(patient_admittance) if ( angle < −2 OR angle > 1.2 )  AirwayState = CLOSED; else if ( angle < 0.9 AND angle > −1.5 )  AirwayState = OPEN; else   AirwayState = UNKNOWN; end ifwhere angle is in radians. The acceptable values for the thresholds maybe any that permits the separation of values representing open andclosed apneas determined from FIG. 4.

The patient resistance at 4 Hz also indicates the state of the airway.This resistance is not the reciprocal of the conductance in the aboveequation. The patient impedance a 4 Hz is

$Z = {{R + {{iX}\mspace{14mu}{where}\mspace{14mu} Y}} = {\frac{1}{Z}.}}$The patient resistance R is given by

$R = {{{Re}(Z)} = {{Re}( \frac{1}{Y} )}}$

In an alternative embodiment R may be used to characterize the state ofthe airway rather than |Y|.

Calculating Admittance

Patient admittance is calculated by the equation

${Y_{pat} = \frac{Q_{{pat},{AC}}}{P_{{mask},{AC}}}},$where the numerator is the magnitude of the AC patient flow, which is ineffect a measure of the differential (with respect to time) of patientflow. The denominator is the same differential of the mask pressure.Correcting for Vent Flow and Leak

The patient airflow is determined by subtracting flow through the ventand leakage flow from the inflow to the mask.Q _(pat,AC) =Q _(maskin,AC) −Q _(vent,AC) −Q _(leak,AC)

The mean vent flow is determined either from mean mask pressure duringthe period of measurement, or more preferably from the square of themean of the square root of the mask pressure during this time (which isalso used to make leak calculations). The mask pressure itself iscalculated in the conventional way, ignoring AC behavior of the airpath.

AC vent flow is calculated using a linear approximation about theoperating point:

$Q_{{vent},{AC}} = {P_{{mask},{AC}}\frac{\mathbb{d}Q_{vent}}{\mathbb{d}P_{mask}}}$Modeling Mask Pressure to Determine AC Flow at Mask

The mask pressure is determined by evaluating the coefficients k.sub.1and k.sub.2 in the equation which gives the pressure drop across thevent as a function of vent flow:P _(mask) =k ₁ Q _(vent) +k ₂ Q _(vent) ².

Thus to calculate the vent flow at a particular mask pressure, onesolves the quadratic equation for vent flow at that mask pressure.

$\frac{\mathbb{d}Q_{vent}}{\mathbb{d}P_{mask}}$can be obtained by differentiation of the previous equation, which gives

$\frac{\mathbb{d}P_{mask}}{\mathbb{d}Q} = {k_{1} + {2\; k_{2}Q_{vent}}}$Since${\frac{\Delta\; Q}{\Delta\; P} \approx \frac{\mathbb{d}Q}{\mathbb{d}P}},$

a small-signal approximation yields

${{\Delta\; Q} \approx {\Delta\; P\frac{\mathbb{d}Q}{\mathbb{d}P}}},$

from which it follows as a reasonable approximation that

$Q_{{vent},{AC}} = {\frac{P_{{mask},{AC}}}{k_{1} + {2\; k_{2}Q_{vent}}}.}$Calculating Leakage Flow

To complete the calculation of the patient airflow it is necessary toalso calculate the leakage flow from the inflow to the mask. The actualleak is calculated over the time period during which the patient 4 Hzadmittance is calculated. Typical leak coefficient estimates relate towhat happened some time ago, and one may, as in the prior art AutoSet CSand AutoVPAP devices estimate the leak coefficient K_(leak) from

$K_{leak} = \frac{\overset{\_}{Q_{nonvent}}}{\overset{\_}{\sqrt{P_{mask}}}}$where the overbars indicate the mean over the measurement period. Duringapnea the leak is equal to the total non-vent flowQ _(nonvent) =Q _(FGTotal) −Q _(vent)and during breathing, the leak is (to a good approximation) equal to theaverage non-vent flow. In the above estimation of K_(leak), allquantities are calculated without reference to the AC characteristics ofthe airpath, based on instantaneous values, treating the airpath as anonlinear resistor.

The model for instantaneous leak, both DC (on which the above formulafor K_(leak) is based) and AC isQ _(leak) =K _(leak)√{square root over (P _(mask))}and, as with vent flow, the AC component (at 4 Hz) of leak flow is foundusing the small-signal approximation

$Q_{{leak},{AC}} = {P_{{mask},{AC}}\frac{\mathbb{d}Q_{leak}}{\mathbb{d}P_{mask}}}$where we may calculate

$\frac{\mathbb{d}Q_{leak}}{\mathbb{d}P_{mask}}$by differentiating the above equation directly, giving

$\frac{\mathbb{d}Q_{leak}}{\mathbb{d}P_{mask}} = {\frac{K_{leak}}{2\;\sqrt{P_{mask}}}.}$

The mean for √{square root over (R_(mask))}, may be either √{square rootover (P_(mask) )} or √{square root over (P_(mask))}. The latter ispreferred (because it gives an unbiased estimate of the mean value of

$\frac{\mathbb{d}Q_{leak}}{\mathbb{d}P_{mask}}$when P_(mask) is not constant, and we have already calculated it inorder to estimate K_(leak)), yielding

$\frac{\mathbb{d}Q_{leak}}{\mathbb{d}P_{mask}} = {\frac{\overset{\_}{Q_{numvent}}}{2( \overset{\_}{\sqrt{P_{mask}}} )^{2}}.}$Determination of AC Values

Throughout this description, the AC values referred to are determinedfrom measurements as trigonometric Fourier components at the excitingfrequency. This is an improvement over the prior art use of the forcedoscillation technique, which used square waves as an orthonormal set offunctions.

All AC quantities are calculated as complex numbers. In particular, theAC pressure and flow at the mask are calculated by finding the sine andcosine components of instantaneous pressure and flow oven the period ofmeasurement using the inner products with the sine and cosine functionrespectively, yielding component coefficients c_(s) and c_(c), thenwriting either c_(s)+ic_(c) or c_(c)+ic_(s) as the AC value. (Either ofthese two forms is used, the two forms differing merely in a phaseshift, but the one form is used consistently throughout). Alternativelyother standard methods of estimating the amplitude and phase of thesinusoidal component of the pressure and flow at the exciting frequencymay be used, such as least-squares fitting of a sine and a cosine.

Explicitly we have

${c_{s} = {\frac{1}{T}{\int_{0}^{2\;{\pi/w}}{{f(t)}{\sin( {\omega\; t} )}\ {\mathbb{d}t}}}}};$${c_{C} = {\frac{1}{T}{\int_{0}^{2\;{\pi/w}}{{f(t)}{\cos( {\omega\; t} )}\ {\mathbb{d}t}}}}};$where the exciting frequency is T/2B, T is a normalizing factor, and theintegral may be replaced by a summation using discrete sampled values ofsine and cosine. f(t) is any function whose Fourier coefficients arerequired.

All quantities are determined over a 6 second sliding window (the“admittance window”) symbolically indicated as t=0. An admittancecalculation can in principle be made at the algorithmic samplingfrequency (say 50 Hz), but for clinical purposes this is not essential,and the calculation may be efficiently performed at the end of every 4Hz cycle. Alternatively, calculation of admittance at 2 Hz or even 1 Hzfrequencies is reasonable for clinical purposes.

Due to motor controller delays, the first cycle (250 ms) of the pressurewaveform may not be sinusoidal, and there will be some delay in settingup a steady state in the airpath, so the first 250 ms of data may beignored.

The sine and cosine values would be stored in a table generated atstartup or specified as constants in the source code. Sufficientaccuracy is provided if multiplications are fixed point, 16 bit*16 bitwith a 32 bit result, assuming of course that overflow of the sum doesnot occur, and there are no numerical stability issues with thisapproach. Thus the computational cost is relatively small.

Modeling Impedance on a Two Port Network

The calculation of AC pressure at the mask and AC flow entering the maskis in one embodiment determined from a 2-port electrical networkanalogue of the flow in the system at a particular frequency.

From FIG. 3, routine circuit analysis gives

V_(out) = V_(i n) − I_(i n)Z_(i n out)$I_{out} = {I_{i\; n} - \frac{V_{out}}{Z_{{out}\;{gnd}}}}$

and of course these correspond to pressure and the mask and flowentering the mask respectively. Explicitly:

P_(mask, A C) = P_(FG, A C) − Q_(FG, A C)Z_(i nout)$Q_{{maskin},{A\; C}} = {Q_{{FG},{A\; C}} - \frac{P_{{mask},{A\; C}}}{Z_{{out}\;{gnd}}}}$

The impedances Z_(inout) and Z_(outgnd) are taken to be functions ofaverage flow. These impedances are measured for a particular airpath ata number of average flow levels (see below for details). The averagetotal flow generator flow during the admittance window is determined,and for each of Z_(inout) and Z_(outgnd), is used to linearlyinterpolate between the measured impedances to determine the impedanceat that average flow level.

The inlet and outlet AC flows and AC pressures are determined over aperiod of 30 seconds (to reduce noise) using the standard inner productmethod described above for the calculation of Fourier coefficients,yielding complex values. These values are used to calculate the 2-portparameters (refer to FIG. 1, where voltages and currents in that figurecorrespond to pressures and flows respectively in the following), by:

$Z_{i\; n\;{out}} = \frac{P_{i\; n} - P_{out}}{Q_{i\; n}}$$Z_{outgnd} = \frac{P_{out}}{Q_{i\; n} - Q_{out}}$If the denominators are very small or zero, the impedances are taken tohave some numerically very large value in relation to typical airpathimpedances.The Hose Pressure Drop Theoretical Model

The hose drop is the pressure difference between the internal maskpressure and the FG pressure. It is the pressure loss across allcomponents that are placed before the mask. This includes mufflers,humidifiers, AB filters and the mask connection hose.

The complete hose drop is made up of the resistive hose drop as well asthe inertial pressure drop

$P_{hosedrop} = {{K_{1}Q_{FG}^{2}} + {K_{2}Q_{FG}} + {K_{L}\frac{\mathbb{d}Q_{FG}}{\mathbb{d}t}}}$K₁, K₂=empirically derived constantsK_(L)=theoretically determined flow inertance constantQ_(FG)=FG Flow

${K_{L} = \frac{\rho\; l}{A}},$ρ=air density (1.19 kg/m³)l=tube length (2 or 3 m)A=cross sectional area 4

$( {\frac{\pi\; d^{2}}{4},{d = {0.019\mspace{14mu} m}}} )$

In the case of masks such as the ResMed Activa and Swift masks there isanother tube between the main hose and the mask. This must also be takeninto account in the inertial constant.

The mean hose drop is made up of purely the resistive part (the over barindicates mean):P _(hosedrop) =K ₁ Q _(FG) +K ₂ Q _(FG)K₁, K₂=empirically derived constantsQ _({circumflex over (F)}G) =Mean FG Flow

In order to calculate the AC hose drop some linearization is necessary.The resistive and inertial components are separated. The resistivecomponent is derived by linearizing the above mean hose drop formulaabout the operating point.

$\frac{\mathbb{d}P_{hosedrop}}{\mathbb{d}Q_{FG}} = {{2K_{1}Q_{FG}} + K_{2}}$$P_{{{hosedrop}\mspace{14mu}{resisitive}},{A\; C}} = {( {{2K_{1}{\overset{\_}{Q}}_{FG}} + K_{2}} )Q_{{FG},{A\; C}}}$

The AC hose drop is thus the AC flow multiplied by gradient of the hosenon-linear resistance at the location around which the small oscillationoccurs. For the derivation it is assumed that the oscillations are of asmall magnitude compared to the change in the gradient of the hoseresistance.

The inertial component is a constant multiplied by the time derivativeof the FG flow. By standard linear circuit theory, an inductance L hasimpedance sL, which for sinusoidal signals at the frequency ω is jωL.The inertial hose drop component then becomes:P _(hosedrop iner lan ce,AC) =K _(L) jωQ _(FG,AC)ω=2πfCombining the two givesP _(drop,AC)=(2K ₁ Q _(FG) +K ₂ +K _(L) jω)Q _(FG,AC)Mask Pressure

The mask pressure is the FG pressure minus the hose pressure drop:P _(mask) =P _(FG) −P _(hose drop)P _(mask,AC) =P _(FG,AC) −P _(hose drop,AC)

Examples

In FIG. 4 a plot is presented in which the thick lines represent openapneas and the thin lines represent closed apneas. The horizontal axisrepresents the absolute magnitude of the admittance, while the verticalaxis represents the phase of the complex admittance. As may be seen fromthe figure, there is a complete separation of the open apneas,represented by the thick curves in the center of the graph, from theclosed apneas, represented by the two thinner curve regions, one nearthe origin and the other at the extreme upper value of the y axis. Ifone looks only at the absolute value of the admittance, in effect byprojecting all of the data onto the x axis, the separation of the datais lost, with the projection of the thin (closed apnea) curves meetingthe projection of the thick (open apnea) data.

FIG. 4 shows the result of plotting patient admittance data calculatedaccording to the formulas above. The x axis values are the averageabsolute value of the patient admittance. The y axis values are thephase angle of the patient admittance. As may be seen from FIG. 4 thereis a clean separation of the values for closed apneas and for openapneas.

FIG. 5 shows the result of plotting patient admittance where instead ofthe previous calculation of admittance a value for the complexadmittance is determined from a model that is essentially independent ofthe modelling details of any particular configuration of mask orventilation circuit. In particular, the data for FIG. 5 were determinedby using a simple leak orifice model P=(KQ)². It may be seen from FIG. 5that the open and closed apneas result in separated regions of the plotof the complex admittance.

Moderate (Approximated Patient Admittance) Algorithm

The third algorithm attempts to approximate the patient admittance bygenerically modeling the patient circuit and combining the leak and ventflows.

The patient circuit is modeled in the same way as the Complex algorithmabove, however the constants are fixed at those for a 2 m hose with ABfilter.

The leak and vent flow modeling are combined into one parameter which isthe non patient flow. This is modeled as

Leak+Vent Flow

The leak and vent flow are combined and modeled as using the followingequations:

The leak orifice can be approximated at runtime using:

$K_{leak} = \frac{\overset{\_}{Q_{FG}}}{\sqrt{P_{mask}}}$

The instantaneous leak is then calculated usingQ _(leak) =K _(leak)√{square root over ( P _(mask) )}

Using small signal approximation we can say that

$Q_{{leak},{A\; C}} = {P_{{mask},\;{A\; C}}\frac{\mathbb{d}Q_{leak}}{\mathbb{d}P_{mask}}}$${{where}\mspace{14mu}\frac{\mathbb{d}Q_{leak}}{\mathbb{d}P_{mask}}} = \frac{K_{leak}}{2\sqrt{P_{mask}}}$(from instantaneous leak equation)substituting in K_(leak) we get

${Q_{{leak},{A\; C}} = {P_{{mask},\;{A\; C}}\frac{\overset{\_}{Q_{FG}}}{2( \sqrt{P_{mask}} )^{2}}}},$as we are dealing with small mean Pmask changes we can approximate√{square root over (P_(mask))} ² with P_(mask) so the AC leak becomes

$Q_{{leak},{A\; C}} = {P_{{mask},\;{A\; C}}\frac{\overset{\_}{Q_{FG}}}{2\;\overset{\_}{P_{mask}}}}$Approximated Patient Flow

The patient flow is thenQ _(patient,AC) =Q _(FG,AC) −Q _(leak,AC)

Qleak is the leak flow combined with the vent flow (all non patientflow).

Classification

There are a number of ways to use the approximated admittance toclassify the airway state. Good separation in just the angle can be seenwhen plotting the angle vs magnitude of the admittance. Therefore asimple classification would be to have two thresholds, but purely onangle. However the calculation of the angle involves a division and aninverse tan, requiring more calculation. It is suggested that it ispreferable to have the real and imaginary parts of the admittance usedinstead.

Thresholds

The simplest thresholds which provide good classification accuracy aresimple straight diagonal lines. These are of the form y>x+b and y<x+c.In this case when plotting the imaginary part (y) vs the real part (x)of the admittance, CLOSED is y>x+b, and OPEN is y<x+c. Based on thefloating-point algorithm the values for the constants were b=0, c=−0.03.This gave no misclassification. Any other curves that separate the dataregions could be used, but the linear separation reduces thecomplication of the threshold calculations and is for that reasonpreferred.

Alternative Embodiment

In an alternative embodiment, the patient impedance is first measuredduring normal breathing, for example at the end of the expiratoryportion of the breath. This measured impedance is averaged over apredetermined time period. The average normal impedance value iscompared to the measured impedance during a detected apnea. Thedetermination of an open or closed airway based on impedance is thenperformed.

This alternative method has the advantages of taking into account theentire patient circuit including the patient's airway and makesunnecessary the requirement for the patient circuit components to becharacterized. In addition this system automatically takes into accountthe current altitude and ambient conditions.

The system allows for plausibility data to be generated using fuzzylogic. For example if a strange impedance measurement is obtained whenthe patient is breathing normally then the algorithm can detect this anddeliver an implausible result. Also wildly varying impedance values mayindicate a fault in the system. The system may also detect ifinappropriate components are present in the system and deliver an error.

The invention claimed is:
 1. A method for determining occurrence of anapnea with a processor of a positive airway pressure apparatuscomprising: measuring respiratory air flow from a patient's airway toprovide an air flow signal from a sensor, applying an oscillatorypressure waveform of known frequency to the patient's airway, in theprocessor calculating a complex quantity representing a patientadmittance based on the air flow signal, in the processor, comparingvalues of the complex quantity with regions indicative of patency orclosed airways, and with the processor, indicating the occurrence of theapnea based on the comparing.
 2. The method for determining theoccurrence of an apnea of claim 1, further comprising in the processorcomparing a patient admittance with admittance during normal breathing.3. The method of claim 1 further comprising controlling a change totreatment pressure provided by the positive airway pressure apparatusbased on the occurrence of apnea.
 4. The method of claim 3 wherein thechange is an increase in pressure when the comparing indicates a closedairway apnea.
 5. The method of claim 3 wherein the change is a decreasein pressure when the comparing indicates a patent airway apnea.
 6. Amethod of a processor of a positive airway pressure apparatus fordistinguishing between closed and open respiratory apneas in a patientusing the positive airway pressure apparatus having a mask and a flowgenerator, the method comprising: controlling, with the processor,application of a pressure wave having a waveform of some amplitude atthe flow generator, determining magnitude of the pressure waveform atthe mask with a sensor, adjusting the pressure amplitude at the flowgenerator to produce a desired amplitude at the mask, determiningpatient admittance in the processor and comparing, in the processor, thedetermined admittance to values representative of closed or open apneasto distinguish an apnea, wherein an output of the processor includes atleast one of logging the distinguished apnea or changing treatmentpressure of the positive airway pressure apparatus based on thedistinguished apnea.
 7. The method for distinguishing between closed andopen respiratory apneas of claim 6, wherein the adjusting the pressureamplitude is accomplished by increasing pressure at the flow generatorby a ratio of desired to actual pressure magnitude at the mask.
 8. Themethod of claim 6 further comprising controlling a change to treatmentpressure provided by the positive airway pressure apparatus based on thedistinguished apnea.
 9. The method of claim 8 wherein the change is anincrease in pressure when the distinguished apnea is a closed apnea. 10.The method of claim 8 wherein the change is a decrease in pressure whenthe distinguished apnea is an open apnea.
 11. Apparatus for determiningoccurrence of an apnea comprising: a sensor for measuring respiratoryair flow from a patient's airway to provide an air flow signal, apositive airway pressure apparatus including a processor, the positiveairway pressure apparatus configured to apply an oscillatory pressurewaveform of known frequency to the patient's airway, wherein theprocessor is configured to: calculate a complex quantity representing apatient admittance based on the air flow signal, compare values of thecomplex quantity with regions indicative of patency or closed airways,and indicate the occurrence of the apnea based on the comparison. 12.The apparatus of claim 11, wherein the processor is further configuredto compare a patient admittance with admittance during normal breathing.13. The apparatus of claim 11 wherein the processor is furtherconfigured to control a change to treatment pressure provided by thepositive airway pressure apparatus based on the occurrence of apnea. 14.The apparatus of claim 13 wherein the change is an increase in pressurewhen the comparing indicates a closed airway apnea.
 15. The apparatus ofclaim 13 wherein the change is a decrease in pressure when the comparingindicates a patent airway apnea.
 16. Positive airway pressure apparatusfor distinguishing between closed and open respiratory apneas in apatient using the positive airway pressure apparatus with a mask, thepositive airway pressure apparatus comprising: a flow generatorincluding a processor, the processor configured to: control applicationof a pressure wave having a waveform of some amplitude at the flowgenerator, determine magnitude of the pressure waveform at the mask witha sensor, adjust the pressure amplitude at the flow generator to producea desired amplitude at the mask, determine patient admittance, andcompare the determined admittance to values representative of closed oropen apneas to distinguish a detected apnea wherein an output of theprocessor includes at least one of log the distinguished apnea or changetreatment pressure of the flow generator based on the distinguishedapnea.
 17. The apparatus of claim 16, wherein the processor adjusts thepressure amplitude by increasing pressure at the flow generator by aratio of desired pressure magnitude at the mask to actual pressuremagnitude at the mask.
 18. The apparatus of claim 16 wherein theprocessor is further configured to control a change to treatmentpressure provided by the positive airway pressure apparatus based on thedistinguished apnea.
 19. The apparatus of claim 18 wherein the change isan increase in pressure when the distinguished apnea is a closed apnea.20. The apparatus of claim 18 wherein the change is a decrease inpressure when the distinguished apnea is an open apnea.